home *** CD-ROM | disk | FTP | other *** search
/ The Games Machine 76 / XENIATGM66.iso / Indiana Jones / Indiana Jones.exe / RESOURCE / PREVIEW.GOB / cog_sol_hints.cog < prev    next >
Text File  |  1999-11-15  |  30KB  |  854 lines

  1. # Jones 3D Cog Script
  2. #
  3. # SOL_Hints.cog
  4. #
  5. # [TRM]
  6. #
  7. # (C) 1999 LucasArts Entertainment Co. All Rights Reserved
  8. # ========================================================================================
  9.  
  10. symbols        
  11.     
  12.     message     user0
  13.     message     user1
  14.     message     user2
  15.     message     entered
  16.     message     activated
  17.     message     boarded
  18.     message     removed
  19.     
  20.     # ** local stuff **
  21.     thing       player      local
  22.     thing       car         local
  23.     
  24.     # ** misc things **
  25.     thing       mineCar
  26.     thing       minePlayer
  27.     thing       fuseBox
  28.     thing       pyrKey
  29.     thing       oilKey
  30.     #thing       blueGem
  31.     thing       redGem
  32.     thing       greenGem
  33.     
  34.     thing       lever1
  35.     thing       lever2
  36.     thing       lever3
  37.     
  38.     # ** hint stuff **
  39.     thing       hint1       # Level 13-SOL. Hint 1: jump x: Indy opens control room door for the first time.
  40.     thing       hint2       # Level 13-SOL. Hint 2: jump 11: Indy visits fuse box for the first time.
  41.     thing       hint3       # Level 13-SOL. Hint 3: jump x: Get back into the mine car at control room.
  42.     thing       hint4       # Level 13-SOL. Hint 4: jump 5: Get out of the mine car, get fuse from fuse cart.
  43.     thing       hint5       # Level 13-SOL. Hint 5: jump 5: Get back into the mine car at exit complex.
  44.     thing       hint6       # Level 13-SOL. Hint 6: jump 11: Get out of the mine car, put fuse in fuse box.
  45.     thing       hint7       # Level 13-SOL. Hint 7: jump 11: lever1, lever3, drive to east end.
  46.     
  47.     thing       hint8       # Level 13-SOL. Hint 9: jump x: Drive mine car just past track merge, then back down siding until you trigger Horus Room mine safety doors to open.
  48.     thing       hint9       # Level 13-SOL. Hint 10: jump x: Whip swing thru waterfall and pick up Eye of Horus.
  49.     thing       hint10      # Level 13-SOL. Hint 11: jump x: Get back into mine car and drive back to Control Room.
  50.     thing       hint11      # Level 13-SOL. Hint 12: jump x: Pull lever 2 to solve.
  51.     thing       hint12      # Level 13-SOL. Hint 13: jump x: Get back in mine car, chase comCar (after chaseLower cutscene).
  52.     thing       hint13      # Level 13-SOL. Hint 14: jump x: Hint appears on comCar -- chase comCar until blowIt is triggered.
  53.     thing       hint14      # Level 13-SOL. Hint 15: jump x: Get out of the mine car and get the oil key from the open room.
  54.     thing       hint15      # Level 13-SOL. Hint 16: jump x: Get back into the mine car and drive to oil shed room. 
  55.     thing       hint16      # Level 13-SOL. Hint 17: jump x: Get out of the mine car and get the oil can from the oil shed. 
  56.     thing       hint17      # Level 13-SOL. Hint 18: jump x: Get back in the mine car and drive to switch4. 
  57.     thing       hint18      # Level 13-SOL. Hint 19: jump x: Get out of the mine car and oil switch4 with the oil can. 
  58.     thing       hint19      # Level 13-SOL. Hint 20: jump x: Get back into the mine car and drive to the control room. 
  59.     thing       hint20      # Level 13-SOL. Hint 21: jump x: Get out of mine car, go in control room and pull lever4 to solve.
  60.     thing       hint21      # Level 13-SOL. Hint 22: jump x: Get back in mine car and drive to swith5 room.
  61.     thing       hint22      # Level 13-SOL. Hint 23: jump x: Get out of mine car and walk up hill towards comFalls.
  62.     thing       hint23      # Level 13-SOL. Hint 24: jump x: Whip swing across broken track and smash wall with IMP1. 
  63.     thing       hint24      # Level 13-SOL. Hint 25: jump x: Pick up the blue gem. 
  64.     thing       hint25      # Level 13-SOL. Hint 26: jump x: Walk back to the mine car and get in. 
  65.     thing       hint26      # Level 13-SOL. Hint 27: jump x: 
  66.     thing       hint27      # Level 13-SOL. Hint 28: jump x: 
  67.     thing       hint28      # Level 13-SOL. Hint 29: jump x: 
  68.     thing       hint29      # Level 13-SOL. Hint 30: jump x: 
  69.     thing       hint30      # Level 13-SOL. Hint 30: jump x: 
  70.     thing       hint31      # Level 13-SOL. Hint 30: jump x: 
  71.     thing       hint32      # Level 13-SOL. Hint 30: jump x: 
  72.     thing       hint33      # Level 13-SOL. Hint 30: jump x: 
  73.     thing       hint34      # Level 13-SOL. Hint 30: jump x: 
  74.     
  75.     # ** sectors **
  76.     sector      sec_ExitComp1
  77.     sector      sec_CtrlRoom
  78.     sector      sec_Switch5
  79.     sector      sec_RedGem
  80.     sector      sec_EastEnd
  81.     sector      sec_OilShed
  82.     sector      sec_Switch4
  83.     sector      sec_Switch5
  84.     sector      sec_Switch5_2
  85.     sector      sec_Reflec
  86.     sector      sec_ExitComp2
  87.     sector      sec_ExitComp3
  88.     
  89.     # ** switch surfaces **
  90.     surface     switch1
  91.     surface     switch2
  92.     surface     switch3
  93.     surface     switch4
  94.     surface     switch5
  95.     
  96.     # ** surfaces **
  97.     surface     surf_HorusOpen
  98.     
  99.     cog         cog_FuseBox
  100.     cog         cog_FuseCart
  101.     cog         cog_CtrlDoor
  102.     cog         cog_OilShed
  103.     cog         cog_lever4
  104.     cog         cog_comFalls
  105.     cog         cog_ExpDebris   # imp wall
  106.     cog         cog_BlueGem
  107.     cog         cog_GemWall     # crate wall
  108.     cog         cog_ChaseLower
  109.     cog         cog_Ambush
  110.     
  111.     # ** hint is attached to mine car **
  112.     int         hint3_Attached=0    local
  113.     int         hint5_Attached=0    local
  114.     int         hint7_Attached=0    local   #new
  115.     int         hint10_Attached=0   local
  116.     int         hint12_Attached=0   local   #new
  117.     int         hint14_Attached=0   local
  118.     int         hint16_Attached=0   local   #new
  119.     int         hint18_Attached=0   local
  120.     int         hint22_Attached=0   local
  121.     int         hint25_Attached=0   local
  122.     int         hint26_Attached=0   local   #new
  123.     int         hint27_Attached=0   local   #new
  124.     
  125.     # ** hint ready for trigger ints **
  126.     int         ready_Hint3=0       local
  127.     int         ready_Hint5=0       local
  128.     int         ready_Hint7=0       local   #new
  129.     int         ready_Hint8=0       local
  130.     int         ready_Hint13=0      local   #new
  131.     int         ready_Hint15=0      local   #new
  132.     int         ready_Hint17=0      local
  133.     int         ready_Hint18=0      local
  134.     int         ready_Hint19=0      local
  135.     int         ready_Hint23=0      local
  136.     int         ready_Hint26=0      local   #new
  137.     int         ready_Hint27=0      local   #new
  138.     int         ready_Hint28=0      local   #new
  139.     
  140.     # ** hints are ready to be attached **
  141.     int         attach_Hint3=0      local   #new
  142.     int         attach_Hint5=0      local
  143.     int         attach_Hint7=0      local   #new
  144.     int         attach_Hint10=0     local   #new
  145.     int         attach_Hint12=0     local   #new
  146.     int         attach_Hint14=0     local   #new
  147.     int         attach_Hint16=0     local
  148.     int         attach_Hint18=0     local
  149.     int         attach_Hint22=0     local
  150.     int         attach_Hint25=0     local   #new
  151.     int         attach_Hint26=0     local   #new
  152.     int         attach_Hint27=0     local   #new
  153.     
  154.     # ** found items **
  155.     int         got_Fuse=0          local
  156.     int         got_OilKey=0        local
  157.     int         got_OilCan=0        local
  158.     int         got_Horus=0         local
  159.     int         got_BlueGem=0       local
  160.     int         got_GreenGem=0      local
  161.     int         got_RedGem=0        local
  162.     
  163.     # ** misc ints **
  164.     int         ready_Boarded=0     local
  165.     int         blown_Ambush=0      local
  166.     int         hint7_Solved=0      local
  167.     int         hint26_Solved=0     local
  168.     
  169. end
  170.  
  171. # ========================================================================================
  172.  
  173. code
  174.  
  175. user0:
  176.  
  177.     if((GetSenderRef() == minecar)  || (GetSenderRef() == minePlayer)) return;
  178.  
  179.     Print("Hints: user0");
  180.     
  181.     # activates control room door (message sent by sol_CtrlRmDoor)
  182.     if((GetSenderRef() == cog_CtrlDoor) && (GetHintSolved(hint1) == 0))
  183.     {
  184.         SetHintSolved(hint1);
  185.     }
  186.     
  187.     # picks up fuse from fuse cart (message sent by fuseCart)
  188.     else if((GetSenderRef() == cog_FuseCart) && (GetHintSolved(hint4) == 0))
  189.     {
  190.         got_Fuse = 1;
  191.         CopyOrientandPos(mineCar, hint5);
  192.         SetHintSolved(hint4);
  193.         ready_Boarded = 1;
  194.         ready_Hint5 = 1; # hint5 is ready for trigger
  195.         attach_Hint5 = 1; # hint5 is ready to be attached
  196.         # hint5 appears at mine car
  197.     }
  198.     
  199.     # put the fuse in the fuse box (message sent by fuseBox)
  200.     else if((GetSenderRef() == cog_FuseBox) && (GetHintSolved(hint6) == 0))
  201.     {
  202.         # if they never checked the fuse box the first time
  203.         if((GetHintSolved(hint2) == 0) && (got_Fuse == 1))
  204.         {
  205.             Print("solved: hint2 thru hint5");
  206.             if(GetHintSolved(hint2) == 0) SetHintSolved(hint2);
  207.             if(GetHintSolved(hint3) == 0) SetHintSolved(hint3);
  208.             if(GetHintSolved(hint4) == 0)
  209.             {
  210.                 SetHintSolved(hint4);
  211.                 DestroyThing(hint4);
  212.             }
  213.             #if(GetHintSolved(hint5) == 0) SetHintSolved(hint5);
  214.         }
  215.         
  216.         CopyOrientandPos(lever1, hint7); # move hint7 to lever1
  217.         SetHintSolved(hint6);
  218.         # hint 7 appears at lever1
  219.     }
  220.     
  221.     # chaseLower cutscene ends, hint appears on brass key (message sent by chaseLower)
  222.     else if(GetSenderRef() == cog_ChaseLower)
  223.     {   
  224.         SetHintSolved(hint10);
  225.         DestroyThing(hint10);
  226.         # hint11 appears on brass key
  227.     }
  228.     
  229.     # player picks up oil can (message sent by oilShed)
  230.     else if(GetSenderRef() == cog_OilShed)
  231.     {
  232.         if((GetHintSolved(hint12) == 0) && (hint12 != -1)) SetHintSolved(hint12);
  233.         
  234.         got_OilCan = 1;
  235.         CopyOrientandPos(mineCar, hint14);
  236.         SetHintSolved(hint13);
  237.         ready_Boarded = 1;
  238.         attach_Hint14 = 1; # hint14 ready to be attached 
  239.         # hint14 appears at minecar
  240.     }
  241.         
  242.     # player oils switch4 (message sent by ctrlLever4)
  243.     else if(GetSenderRef() == cog_lever4)
  244.     {   
  245.         if((GetHintSolved(hint14) == 0) && (hint14 != -1)) SetHintSolved(hint14);
  246.         
  247.         Print("hint15 solved!");
  248.         CopyOrientandPos(mineCar, hint16);
  249.         SetHintSolved(hint15);
  250.         ready_Boarded = 1;
  251.         attach_Hint16 = 1; # hint16 ready to be attached
  252.         # hint16 appears at mine car
  253.     }
  254.     
  255.     # player pulls switch4 to send commies over edge (message sent by comfalls)
  256.     else if((GetSenderRef() == cog_comFalls) && (GetHintSolved(hint17) == 0))
  257.     {
  258.         if((GetHintSolved(hint16) == 0) && (hint16 != -1)) SetHintSolved(hint16);
  259.         
  260.         SetHintSolved(hint17);
  261.         CopyOrientandPos(mineCar, hint18);
  262.         ready_Boarded = 1;
  263.         attach_Hint18 = 1; # hint18 ready to be attached
  264.         ready_Hint18 = 1; # hint18 ready for trigger
  265.         # hint 18 appears at mine car
  266.     }
  267.     
  268.     # player smashes down imp1 wall (message sent by explodingDebris)
  269.     else if((GetSenderRef() == cog_ExpDebris) && (GetHintSolved(hint20) == 0))
  270.     {   
  271.         SetHintSolved(hint20);
  272.         # hint appears on blue gem
  273.     }
  274.     
  275.     # player pickes up blueGem
  276.     if((GetSenderRef() == cog_BlueGem) && (GetHintSolved(hint21) == 0))
  277.     {
  278.         if((GetHintSolved(hint18) == 0) && (hint18 != -1)) SetHintSolved(hint18);
  279.         if(GetHintSolved(hint19) == 0) SetHintSolved(hint19);
  280.         if(GetHintSolved(hint20) == 0) SetHintSolved(hint20);
  281.         
  282.         got_BlueGem = 1;
  283.         CopyOrientandPos(mineCar, hint22);
  284.         SetHintSolved(hint21);
  285.         ready_Boarded = 1;
  286.         attach_Hint22 = 1; # hint22 ready to be attached
  287.         # hint22 appears at mine car
  288.         
  289.         # player has already put in pyrKey
  290.         if(GetHintSolved(hint29) == 1)
  291.         {
  292.             if((GetHintSolved(hint27) == 0) && (hint27 != -1)) SetHintSolved(hint27);
  293.             if(GetHintSolved(hint28) == 0) SetHintSolved(hint28);
  294.         }
  295.         
  296.         if((got_RedGem == 1) && (got_GreenGem == 1) && (got_BlueGem == 1) && (got_Horus == 1))
  297.         {
  298.             ready_Hint27 = 1;
  299.         }
  300.     }
  301.     
  302.     # player blows up wall behind crate
  303.     else if((GetSenderRef() == cog_GemWall) && (GetHintSolved(hint23) == 0))
  304.     {   
  305.         if((GetHintSolved(hint22) == 0) && (attach_Hint22 == 1))
  306.         {
  307.             attach_Hint22 = 0;
  308.             SetHintSolved(hint22);
  309.         }
  310.         
  311.         SetHintSolved(hint23);
  312.         # hint24 appears on red gem
  313.     }
  314.     
  315.     # triggers ambush cutscene
  316.     else if((GetSenderRef() == cog_Ambush) && (ready_Hint26 == 1) && (blown_Ambush == 0))
  317.     {
  318.         ready_Hint26 = 0;
  319.         CopyOrientandPos(greenGem, hint26); # move hint26 to greenGem
  320.     }
  321.     
  322.     return;
  323.  
  324. # ========================================================================================
  325.  
  326. user1:
  327.  
  328.     if((GetSenderRef() == minecar)  || (GetSenderRef() == minePlayer)) return;
  329.     if((hint7_Solved == 1) && (hint26_Solved == 1)) return;
  330.     
  331.     Print("Hints: user1");
  332.     
  333.     if(hint7_Solved == 0)
  334.     {
  335.         if(BitTest(GetThingAttachFlags(hint7), 0x08))
  336.         {
  337.             ClearThingAttachFlags(hint7, 0x08);
  338.             DetachThing(hint7);
  339.         }
  340.     }
  341.     
  342.     else
  343.     {
  344.         if(BitTest(GetThingAttachFlags(hint26), 0x08))
  345.         {
  346.             ClearThingAttachFlags(hint26, 0x08);
  347.             DetachThing(hint26);
  348.         }
  349.     }
  350.  
  351.     # correct position
  352.     if((GetWallCel(switch1) == 2) && (GetWallCel(switch2) == 1) && (GetWallCel(switch3) == 2))
  353.     {
  354.         if(hint7_Solved == 0)
  355.         {
  356.             Print("move hint7 to minecar");
  357.             CopyOrientandPos(mineCar, hint7); # move hint7 to minecar
  358.             ready_Boarded = 1;
  359.             ready_Hint7 = 1; # hint7 is ready for trigger
  360.             attach_Hint7 = 1; # hint7 is ready to be attached
  361.             # hint7 appears at mine car
  362.         }
  363.         
  364.         else
  365.         {
  366.             Print("move hint26 to minecar");
  367.             CopyOrientandPos(mineCar, hint26); # move hint26 to minecar
  368.             ready_Boarded = 1;
  369.             ready_Hint26 = 1; # hint26 is ready for trigger
  370.             attach_Hint26 = 1; # hint26 is ready to be attached
  371.             # hint7 appears at mine car
  372.         }
  373.     }
  374.     
  375.     else if((GetWallCel(switch1) == 1) && (GetWallCel(switch2) == 1) && (GetWallCel(switch3) == 1))
  376.     {
  377.         if(hint7_Solved == 0)
  378.         {
  379.             CopyOrientandPos(lever1, hint7); # move hint7 to lever1
  380.         }
  381.         
  382.         else
  383.         {
  384.             CopyOrientandPos(lever1, hint26); # move hint26 to lever1
  385.         }
  386.     }
  387.     
  388.     else if((GetWallCel(switch1) == 1) && (GetWallCel(switch2) == 2) && (GetWallCel(switch3) == 1))
  389.     {
  390.         if(hint7_Solved == 0)
  391.         {
  392.             CopyOrientandPos(lever1, hint7); # move hint7 to lever1
  393.         }
  394.         
  395.         else
  396.         {
  397.             CopyOrientandPos(lever1, hint26); # move hint26 to lever1
  398.         }
  399.     }
  400.     
  401.     else if((GetWallCel(switch1) == 1) && (GetWallCel(switch2) == 1) && (GetWallCel(switch3) == 2))
  402.     {
  403.         if(hint7_Solved == 0)
  404.         {
  405.             CopyOrientandPos(lever1, hint7); # move hint7 to lever1
  406.         }
  407.         
  408.         else
  409.         {
  410.             CopyOrientandPos(lever1, hint26); # move hint26 to lever1
  411.         }
  412.     }
  413.     
  414.     else if((GetWallCel(switch1) == 2) && (GetWallCel(switch2) == 1) && (GetWallCel(switch3) == 1))
  415.     {
  416.         if(hint7_Solved == 0)
  417.         {
  418.             CopyOrientandPos(lever3, hint7); # move hint7 to lever3
  419.         }
  420.         
  421.         else
  422.         {
  423.             CopyOrientandPos(lever3, hint26); # move hint26 to lever3
  424.         }
  425.     }
  426.     
  427.     else if((GetWallCel(switch1) == 2) && (GetWallCel(switch2) == 2) && (GetWallCel(switch3) == 1))
  428.     {
  429.         if(hint7_Solved == 0)
  430.         {
  431.             CopyOrientandPos(lever2, hint7); # move hint7 to lever2
  432.         }
  433.         
  434.         else
  435.         {
  436.             CopyOrientandPos(lever2, hint26); # move hint26 to lever2
  437.         }
  438.     }
  439.     
  440.     else if((GetWallCel(switch1) == 2) && (GetWallCel(switch2) == 2) && (GetWallCel(switch3) == 2))
  441.     {
  442.         if(hint7_Solved == 0)
  443.         {
  444.             CopyOrientandPos(lever2, hint7); # move hint7 to lever2
  445.         }
  446.         
  447.         else
  448.         {
  449.             CopyOrientandPos(lever2, hint26); # move hint26 to lever2
  450.         }
  451.     }    
  452.     
  453.     return;
  454.     
  455. # ========================================================================================
  456.  
  457. user2:
  458.  
  459.     if(GetSenderRef() == cog_Ambush)
  460.     {
  461.         blown_Ambush = 1;
  462.     }
  463.  
  464.     return;
  465.  
  466. # ========================================================================================
  467.  
  468. entered:
  469.  
  470.     player = GetLocalPlayerThing();
  471.     car = GetSourceRef();
  472.     
  473.     Print("hints: entered");
  474.  
  475.     if(BitTest(GetPhysicsFlags(car), 0x01000000))
  476.     {
  477.         # enters exit complex
  478.         if((GetSenderRef() == sec_ExitComp1) && (ready_Hint3 == 1))
  479.         {
  480.             ready_Hint3 = 0;
  481.             SetHintSolved(hint3);
  482.             DestroyThing(hint3); # remove hint3 from minecar
  483.             # hint4 appears at fuse cart
  484.         }
  485.         
  486.         # enters control room area
  487.         else if((GetSenderRef() == sec_CtrlRoom) && (ready_Hint5 == 1))
  488.         {
  489.             ready_Hint5 = 0;
  490.             SetHintSolved(hint5);
  491.             DestroyThing(hint5);
  492.             # hint6 appears at fuse box
  493.         }
  494.         
  495.         # enters east end
  496.         else if((GetSenderRef() == sec_EastEnd) && (ready_Hint7 == 1))
  497.         {
  498.             ready_Hint7 = 0;
  499.             hint7_Solved = 1;
  500.             SetHintSolved(hint7);
  501.             DestroyThing(hint7);
  502.             ready_Hint8 = 1; # ready hint8 for trigger
  503.             # hint9 appears at horus room pressure pad
  504.         }
  505.         
  506.         # mine car opens horus doors
  507.         else if((GetSenderRef() == surf_HorusOpen) && (ready_Hint8 == 1))
  508.         {
  509.             ready_Hint8 = 0;
  510.             SetHintSolved(hint8);
  511.             # hint9 appears at horus eye
  512.         }
  513.         
  514.         # enters oil shed area
  515.         else if((GetSenderRef() == sec_OilShed) && (ready_Hint13 == 1))
  516.         {
  517.             ready_Hint13 = 0;
  518.             SetHintSolved(hint12);
  519.             DestroyThing(hint12);
  520.             # hint13 appears at oil can
  521.         }
  522.         
  523.         # enters switch4 area
  524.         else if((GetSenderRef() == sec_Switch4) && (ready_Hint15 == 1))
  525.         {
  526.             Print("hint15 appears at switch4");
  527.             ready_Hint15 = 0;
  528.             SetHintSolved(hint14);
  529.             DestroyThing(hint14);
  530.             # hint15 appears at switch4
  531.         }
  532.         
  533.         # enters control room area
  534.         else if((GetSenderRef() == sec_CtrlRoom) && (ready_Hint17 == 1))
  535.         {
  536.             ready_Hint17 = 0;
  537.             SetHintSolved(hint16);
  538.             DestroyThing(hint16);
  539.             # hint17 appears at switch4
  540.         }
  541.         
  542.         ### switch5 enter was here
  543.         
  544.         # enters redGem room
  545.         else if((GetSenderRef() == sec_RedGem) && (ready_Hint23 == 1))
  546.         {
  547.             ready_Hint23 = 0;
  548.             SetHintSolved(hint22);
  549.             DestroyThing(hint22);
  550.             # hint23 appears behind expload wall
  551.         }
  552.         
  553.         # enters reflec room
  554.         else if((GetSenderRef() == sec_Reflec) && (ready_Hint26 == 1) && (blown_Ambush == 1) && (got_GreenGem == 0))
  555.         {
  556.             ready_Hint26 = 0;
  557.             SetHintSolved(hint25);
  558.             CopyOrientandPos(greenGem, hint26); # move hint26 to greenGem
  559.         }
  560.         
  561.         # enters control room area (second time)
  562.         else if((GetSenderRef() == sec_CtrlRoom) && (ready_Hint26 == 1) && (blown_Ambush == 0))
  563.         {
  564.             ready_Hint26 = 0;
  565.             SetHintSolved(hint25);
  566.             SendMessage(GetSelfCog(), user1);   # send hint26 to proper lever
  567.         }
  568.         
  569.         # enters exit complex
  570.         else if((GetSenderRef() == sec_ExitComp2) && (ready_Hint27 == 1))
  571.         {
  572.             ready_Hint27 = 0;
  573.             SetHintSolved(hint27);
  574.             DestroyThing(hint27);
  575.             
  576.             if(GetHintSolved(hint29) == 1)
  577.             {
  578.                 SetHintSolved(hint28);
  579.                 ready_Hint28 = 0;
  580.             }
  581.             
  582.             else ready_Hint28 = 1;   # hint28 is ready to be triggered
  583.         }
  584.     }
  585.     
  586.     #else if((GetSourceRef() == player) || (GetSenderRef() == minePlayer))
  587.     #{ 
  588.         # enters switch5 room
  589.         if((GetSenderRef() == sec_Switch5) && (ready_Hint18 == 1))
  590.         {
  591.             Print("ready_Hint19");
  592.             ready_Hint18 = 0;
  593.             SetHintSolved(hint18);
  594.             DestroyThing(hint18);
  595.             ready_Hint19 = 1; # ready hint19 for trigger
  596.             # hint19 appears near switch5
  597.         }
  598.         
  599.         # player reaches hint19 on foot
  600.         else if((GetSenderRef() == sec_Switch5_2) && (GetHintSolved(hint19) == 0) && (ready_Hint19 == 1))
  601.         {
  602.             ready_Hint19 = 0;
  603.             SetHintSolved(hint19);
  604.             # hint20 appears at IMP1 wall
  605.         }
  606.         
  607.         # player is on his way to final room on foot
  608.         else if((GetSenderRef() == sec_ExitComp3) && (GetHintSolved(hint28) == 0) && (ready_Hint28 == 1))
  609.         {
  610.             ready_Hint28 = 0;
  611.             SetHintSolved(hint28);
  612.             # hint29 appears at pyramid
  613.         }
  614.     #}
  615.     
  616.     return;
  617.     
  618. # ========================================================================================
  619.  
  620. activated:
  621.  
  622.     # visits fuse box for the first time
  623.     if((GetSenderRef() == fuseBox) && (GetHintSolved(hint2) == 0) && (got_Fuse == 0))
  624.     {
  625.         CopyOrientandPos(mineCar, hint3); # move hint3 to minecar
  626.         SetHintSolved(hint2); # solve hint2
  627.         ready_Boarded = 1;
  628.         attach_Hint3 = 1; # hint3 is ready to be attached
  629.         ready_Hint3 = 1; # hint3 is ready for trigger
  630.         # hint3 appears at mine car
  631.     }
  632.     
  633.     if((GetSenderRef() == pyrKey) && (GetHintSolved(hint9) == 0))
  634.     {
  635.         if(GetHintSolved(hint7) == 0) SetHintSolved(hint7);
  636.         if(GetHintSolved(hint8) == 0) SetHintSolved(hint8);
  637.         
  638.         got_Horus = 1;
  639.         CopyOrientandPos(mineCar, hint10);
  640.         SetHintSolved(hint9);
  641.         ready_Boarded = 1;
  642.         attach_Hint10 = 1; # hint10 ready to be attached
  643.         # hint10 appears at mine car
  644.     }
  645.     
  646.     if((GetSenderRef() == oilKey) && (GetHintSolved(hint11) == 0))
  647.     {
  648.         if((GetHintSolved(hint10) == 0) && (hint10 != -1)) SetHintSolved(hint10);
  649.         
  650.         got_OilKey = 1;
  651.         CopyOrientandPos(mineCar, hint12);
  652.         SetHintSolved(hint11);
  653.         ready_Boarded = 1;
  654.         ready_Hint13 = 1; # hint13 is ready to be triggered
  655.         attach_Hint12 = 1; # hint12 ready to be attached
  656.         # hint12 appears at mine car
  657.         
  658.         # player has already put in pyrKey
  659.         if(GetHintSolved(hint29) == 1)
  660.         {
  661.             if((GetHintSolved(hint27) == 0) && (hint27 != -1)) SetHintSolved(hint27);
  662.             if(GetHintSolved(hint28) == 0) SetHintSolved(hint28);
  663.         }
  664.     }
  665.     
  666.     if((GetSenderRef() == redGem) && (GetHintSolved(hint24) == 0))
  667.     {
  668.         if(GetHintSolved(hint22) == 0) SetHintSolved(hint22);
  669.         if(GetHintSolved(hint23) == 0) SetHintSolved(hint23);
  670.         
  671.         got_RedGem = 1;
  672.         CopyOrientandPos(mineCar, hint25);
  673.         SetHintSolved(hint24);
  674.         ready_Boarded = 1;
  675.         attach_Hint25 = 1; # hint25ready to be attached
  676.         # hint25 appears at mine car
  677.         
  678.         # player has already put in pyrKey
  679.         if(GetHintSolved(hint29) == 1)
  680.         {
  681.             if((GetHintSolved(hint27) == 0) && (hint27 != -1)) SetHintSolved(hint27);
  682.             if(GetHintSolved(hint28) == 0) SetHintSolved(hint28);
  683.         }
  684.         
  685.         if((got_RedGem == 1) && (got_GreenGem == 1) && (got_BlueGem == 1) && (got_Horus == 1))
  686.         {
  687.             ready_Hint27 = 1;
  688.         }
  689.     }
  690.     
  691.     if((GetSenderRef() == greenGem) && (GetHintSolved(hint26) == 0))
  692.     {
  693.         if((GetHintSolved(hint25) == 0) && (hint25 != -1) && (got_RedGem == 1)) SetHintSolved(hint25);
  694.         
  695.         Print("got the greenGem");
  696.         got_GreenGem = 1;
  697.         CopyOrientandPos(mineCar, hint27);
  698.         SetHintSolved(hint26);
  699.         hint26_Solved = 1;
  700.         ready_Boarded = 1;
  701.         attach_Hint27 = 1; # hint27ready to be attached
  702.         # hint27 appears at mine car
  703.         
  704.         # player has already put in pyrKey
  705.         if(GetHintSolved(hint29) == 1)
  706.         {
  707.             if((GetHintSolved(hint27) == 0) && (hint27 != -1)) SetHintSolved(hint27);
  708.             if(GetHintSolved(hint28) == 0) SetHintSolved(hint28);
  709.         }
  710.     }
  711.     
  712.     return;
  713.  
  714. # ========================================================================================
  715.  
  716. boarded:
  717.  
  718.     Print("Hints: boarded");
  719.     
  720.     if(ready_Boarded == 1)
  721.     {
  722.         # get in after first visit to fuse box
  723.         if((GetSenderRef() == minePlayer) && (hint3_Attached == 0) && (attach_Hint3 == 1))
  724.         {
  725.             ready_Boarded = 0;
  726.             AttachThingToThingEx(hint3, minePlayer, 0x08);
  727.             hint3_Attached = 1;
  728.         }
  729.         
  730.         # get in after picking up fuse
  731.         else if((GetSenderRef() == minePlayer) && (hint5_Attached == 0) && (attach_Hint5 == 1))
  732.         {
  733.             ready_Boarded = 0;
  734.             AttachThingToThingEx(hint5, minePlayer, 0x08);
  735.             hint5_Attached = 1;
  736.         }
  737.         
  738.         # get in after setting levers correctly
  739.         else if((GetSenderRef() == minePlayer) && (hint7_Attached == 0) && (attach_Hint7 == 1))
  740.         {
  741.             ready_Boarded = 0;
  742.             AttachThingToThingEx(hint7, minePlayer, 0x08);
  743.             hint7_Attached = 1;
  744.         }
  745.         
  746.         # get in after getting horus key
  747.         else if((GetSenderRef() == minePlayer) && (hint10_Attached == 0) && (attach_Hint10 == 1))
  748.         {
  749.             ready_Boarded = 0;
  750.             AttachThingToThingEx(hint10, minePlayer, 0x08);
  751.             hint10_Attached = 1;
  752.         }
  753.         
  754.         # get in after getting oil key
  755.         else if((GetSenderRef() == minePlayer) && (hint12_Attached == 0) && (attach_Hint12 == 1))
  756.         {
  757.             ready_Boarded = 0;
  758.             AttachThingToThingEx(hint12, minePlayer, 0x08);
  759.             hint12_Attached = 1;
  760.         }
  761.         
  762.         # get in after getting oil can
  763.         else if((GetSenderRef() == minePlayer) && (hint14_Attached == 0) && (attach_Hint14 == 1))
  764.         {
  765.             Print("debugging ready_Hint15");
  766.             ready_Boarded = 0;
  767.             AttachThingToThingEx(hint14, minePlayer, 0x08);
  768.             hint14_Attached = 1;
  769.             ready_Hint15 = 1; # hint15 is ready to be triggered
  770.         }
  771.         
  772.         # get in after oiling switch4
  773.         else if((GetSenderRef() == minePlayer) && (hint16_Attached == 0) && (attach_Hint16 == 1))
  774.         {
  775.             ready_Boarded = 0;
  776.             AttachThingToThingEx(hint16, minePlayer, 0x08);
  777.             hint16_Attached = 1;
  778.             ready_Hint17 = 1; # hint17 is ready to be triggered
  779.         }
  780.         
  781.         # get in after pulling switch4
  782.         else if((GetSenderRef() == minePlayer) && (hint18_Attached == 0) && (attach_Hint18 == 1))
  783.         {
  784.             ready_Boarded = 0;
  785.             AttachThingToThingEx(hint18, minePlayer, 0x08);
  786.             hint18_Attached = 1;
  787.         }
  788.         
  789.         # get in after getting blueGem
  790.         else if((GetSenderRef() == minePlayer) && (hint22_Attached == 0) && (attach_Hint22 == 1))
  791.         {
  792.             ready_Boarded = 0;
  793.             AttachThingToThingEx(hint22, minePlayer, 0x08);
  794.             hint22_Attached = 1;
  795.             ready_Hint23 = 1; #hint23 ready to be triggered
  796.         }
  797.         
  798.         # get in after getting redGem
  799.         else if((GetSenderRef() == minePlayer) && (hint25_Attached == 0) && (attach_Hint25 == 1))
  800.         {
  801.             ready_Boarded = 0;
  802.             AttachThingToThingEx(hint25, minePlayer, 0x08);
  803.             hint25_Attached = 1;
  804.             ready_Hint26 = 1; # hint26 is ready to be triggered
  805.         }
  806.         
  807.         # get in after getting greenGem
  808.         else if((GetSenderRef() == minePlayer) && (hint27_Attached == 0) && (attach_Hint27 == 1))
  809.         {
  810.             Print("get in after getting greenGem");
  811.             ready_Boarded = 0;
  812.             AttachThingToThingEx(hint27, minePlayer, 0x08);
  813.             hint27_Attached = 1;
  814.             ready_Hint27 = 1; # hint27 is ready to be triggered
  815.         }
  816.         
  817.         # get in after properly setting up ambush (if didn't do it earlier)
  818.         else if((GetSenderRef() == minePlayer) && (hint26_Attached == 0) && (attach_Hint26 == 1))
  819.         {
  820.             if(hint26_Solved == 0)
  821.             {
  822.                 Print("get in after properly setting up ambush");
  823.                 ready_Boarded = 0;
  824.                 AttachThingToThingEx(hint26, minePlayer, 0x08);
  825.                 hint26_Attached = 1;
  826.                 #ready_Hint26 = 1; # hint26 is ready to be triggered
  827.             }
  828.             
  829.             else Print("get the fuck out of here");
  830.         }
  831.     }
  832.     
  833.     return;
  834.  
  835. # ========================================================================================
  836.  
  837. removed:
  838.  
  839.     if(GetSenderRef() == hint10) hint10 = -1;
  840.     if(GetSenderRef() == hint12) hint12 = -1;
  841.     if(GetSenderRef() == hint14) hint14 = -1;
  842.     if(GetSenderRef() == hint16) hint16 = -1;
  843.     if(GetSenderRef() == hint18) hint18 = -1;
  844.     if(GetSenderRef() == hint22) hint22 = -1;
  845.     if(GetSenderRef() == hint25) hint25 = -1;
  846.     if(GetSenderRef() == hint27) hint27 = -1;
  847.     
  848.     return;
  849.     
  850. # ========================================================================================
  851.  
  852. end
  853.  
  854.